<%@ page language="java"
	import="java.util.*,com.wechat.service.WechatService"
	pageEncoding="UTF-8"%>
<%
    //注意生成注入对象的时候 一定要去掉端口号
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() +  path + "/";
%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="json" uri="http://www.atg.com/taglibs/json"%>
<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>HIFO</title>
		<meta name="viewport"
			content="width=device-width, initial-scale=1, user-scalable=0">
		<link rel="stylesheet" href="css/style.css">
	</head>
	<body ontouchstart="">
		<div class="wxapi_container">
			<div class="wxapi_index_container">
				<ul class="label_box lbox_close wxapi_index_list">

					<li class="label_item wxapi_index_item">
						<a class="label_inner" href="#menu-location">地理位置接口</a>
					</li>

				</ul>
			</div>
			<div class="lbox_close wxapi_form">
				<h3 id="menu-basic">
					基础接口
				</h3>
				<span class="desc">判断当前客户端是否支持指定JS接口</span>
				<button class="btn btn_primary" id="checkJsApi">
					checkJsApi
				</button>


				<span class="desc">获取地理位置接口</span>
				<button class="btn btn_primary" id="getLocation">
					getLocation
				</button>
				<%
					WechatService ws = WechatService.getInstance();
					String url = basePath + "gps_test.jsp";
				%>
				<div><%=url %></div>
				<sapn>kgt8ON7yVITDhtdwci0qeYwDjY_x4xKlZ1GjkhOvm7a5y9f52RGD6dTNf2EKF0_Yv6449Z770J4PfStMUQfCfw&noncestr=697bf961-07a7-4bc7-9ffb-e76267b53942&timestamp=1450879341212&url=http://we.51waji.com/microhifo/gps_test.jsp</span>
			</div>
		</div>
	</body>
	<script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
	<script>
	<%=ws.wxConfig(url) %>
</script>
	<script src="js/gps.js">
	
</script>
</html>
